package jsyf.oa.service.attach;

import com.alibaba.fastjson.JSONObject;
import jsyf.oa.dao.attach.AttachModuleDao;
import jsyf.oa.facade.attach.AttachModuleFacade;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * Created by Administrator on 2017/12/13 0013.
 */
@Service
@Transactional(rollbackFor = Exception.class)
@com.alibaba.dubbo.config.annotation.Service(protocol = {"dubbo"})
public class AttachModuleService implements AttachModuleFacade {
    @Autowired
    private AttachModuleDao attachDao;

    @Override
    public List<JSONObject> getAttachesByModuleId(String moduleId) {
        List<JSONObject> jsonObjectList=attachDao.getByCondition(" and moduleId = ? ", new Object[]{moduleId});
        return jsonObjectList;
    }
}
